<!--
Copyright (C) 2020 Yoann QUERET <yoann@queret.net>
-->

<!--
This file is part of ODR-EncoderManager.

ODR-EncoderManager is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

ODR-EncoderManager is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with ODR-EncoderManager.  If not, see <http://www.gnu.org/licenses/>.
-->


<!DOCTYPE html>
<html lang="en">

{% include 'head.html' %}

<body>
    {% include 'body-nav.html' %}

    <div class="container-fluid">
        <div class="page-header">
            <h1>Help</h1>
        </div>


        <div class="panel-group" id="accordion">
            <div class="panel panel-default">
                <div class="panel-heading">
                <h4 class="panel-title">
                    <a data-toggle="collapse" data-parent="#accordion" href="#collapse1">How to set DLS / DL+</a>
                </h4>
                </div>
                <div id="collapse1" class="panel-collapse collapse">
                <div class="panel-body">
                    <b>Set DLS for all encoder</b>
                    <p>To set text metadata used for DLS, use http GET or POST (Form data) on the Encoder Manager API from your automation software.</p>
                    <pre>http://{ip}:8080/api/setDLS?dls={artist}-{title}</pre>
                    <pre>curl -X POST -F 'dls={artist}-{title}' http://{ip}:8080/api/setDLS</pre>

                    <b>Set DLS for specific encoder</b>
                    <p>If you want to update DLS / DL+ for a specific encoder, you need to find the uniq_id on <a href="/encodermanage">Encoder > Manage</a> page under Information button</p>
                    <pre>http://{ip}:8080/api/setDLS?dls={artist}-{title}&uniq_id={00000000-0000-0000-0000-000000000000}</pre>
                    <pre>curl -X POST -F 'dls={artist}-{title}' -F 'uniq_id={00000000-0000-0000-0000-000000000000}' http://{ip}:8080/api/setDLS</pre>

                    <b>Set DL+</b>
                    <p>As an alternative DL+ tags are automatically activated if you use artist & title parameters:</p>
                    <pre>http://{ip}:8080/api/setDLS?artist={artist}&title={title}</pre>
                    <pre>curl -X POST -F 'artist={artist}' -F 'title={title}' http://{ip}:8080/api/setDLS</pre>

                    <p>Many radio automation software can send this information to Encoder Manager API by using a call of this type (for example)</p>
                    <pre>http://{ip}:8080/api/setDLS?dls=%%artist%% - %%title%%</pre>
                    <p>%%artist%% - %%title%% should be replaced with the expression expected from your radio automation software.</p>
                    <p>At each events on your playlist (when a track start) the radio automation software will send via this url the appropriate metadata to  Encoder Manager API. It will be reflected on the DAB signal.</p>
                </div>
                </div>
            </div>
            <div class="panel panel-default">
                <div class="panel-heading">
                <h4 class="panel-title">
                    <a data-toggle="collapse" data-parent="#accordion" href="#collapse2">How to set SLS (SlideShow)</a>
                </h4>
                </div>
                <div id="collapse2" class="panel-collapse collapse">
                <div class="panel-body">
                    <b>Set SLS for all encoder</b>
                    <p>To send slide used for SLS, use http POST on the Encoder Manager API.</p>
                    <pre>curl -X POST -F 'slide_file=@"live.jpg"' http://{ip}:8080/api/setSLS</pre>

                    <b>Set SLS for specific encoder</b>
                    <p>If you want to update SLS for a specific encoder, you need to find the uniq_id on <a href="/encodermanage">Encoder > Manage</a> page under Information button</p>
                    <pre>curl -X POST -F 'uniq_id={00000000-0000-0000-0000-000000000000}' -F 'slide_file=@"{file.jpg}"' http://{ip}:8080/api/setSLS</pre>
                </div>
                </div>
            </div>
            <div class="panel panel-default">
                <div class="panel-heading">
                <h4 class="panel-title">
                    <a data-toggle="collapse" data-parent="#accordion" href="#collapse3">Lorem ipsum</a>
                </h4>
                </div>
                <div id="collapse3" class="panel-collapse collapse">
                <div class="panel-body">Lorem ipsum dolor sit amet, consectetur adipisicing elit,
                sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad
                minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea
                commodo consequat.</div>
                </div>
            </div>
        </div>


    </div>

</body>

</html>
